package com.tarena.lbs.content.service.impl;

import com.tarena.lbs.content.api.service.ArticleService;
import com.tarena.lbs.content.dao.repository.ArticleRepository;
import com.tarena.lbs.content.pojo.query.ArticleQuery;
import com.tarena.lbs.content.pojo.vo.ArticleVO;
import com.tarena.lbs.content.pojo.vo.BusinessVO;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.beans.factory.annotation.Autowired;
import java.util.List;

/**
 * 文章服务Dubbo实现类，用于跨模块调用
 */
@DubboService
public class ArticleDubboServiceImpl implements ArticleService {
    
    @Autowired
    private ArticleRepository articleRepository;
    
    @Override
    public Integer findArticles(Integer shopId) {
        // 调用ArticleRepository的查询方法
        return articleRepository.findArticles(shopId);
    }

    @Override
    public BusinessVO findBusinessById(Integer id) {
        BusinessVO businessVO = articleRepository.findBusinessById(id);
        return businessVO;
    }
}